home *** CD-ROM | disk | FTP | other *** search
Text File | 1993-10-26 | 1.3 KB | 26 lines | [TEXT/$Tcl] |
-
-
- scancontext ?option?
- This command manages file scan contexts. A scan con-
- text is a collection of regular expressions and com-
- mands to execute when that regular expression matches a
- line of the file. A context may also have a single
- default match, to be applied against lines that do not
- match any of the regular expressions. Multiple scan
- contexts may be defined and they may be reused on mul-
- tiple files. A scan context is identified by a context
- handle. The scancontext command takes the following
- forms:
-
- scancontext create
- Create a new scan context. The scanmatch command is
- used to define patterns in the context. A contexthan-
- dle is returned, which the Tcl programmer uses to refer
- to the newly created scan context in calls to the Tcl
- file scanning commands.
-
- scancontext delete contexthandle
- Delete the scan context identified by contexthandle,
- and free all of the match statements and compiled regu-
- lar expressions associated with the specified context.
-